package org.wyn.mongodb.bean;

import java.util.List;

import org.bson.types.ObjectId;

/**
 * 图片
 * @author wyn
 *
 */
public class Picture {
	private ObjectId fileId;//GridFS中fs.files的_id 
	private String fileName = "";
	private long createTime;
	private List<Comment> comments;//评论
	private int visitCount;//该照片被浏览次数
	public Picture(){
		
	}
	public Picture(ObjectId fileId,String fileName){
		this.fileId = fileId;
		this.fileName = fileName;
		createTime = System.currentTimeMillis();
		visitCount = 0;
	}
	public String getFileName() {
		return fileName;
	}
	public void setFileName(String fileName) {
		this.fileName = fileName;
	}
	public ObjectId getFileId() {
		return fileId;
	}
	public void setFileId(ObjectId fileId) {
		this.fileId = fileId;
	}
	public long getCreateTime() {
		return createTime;
	}
	public void setCreateTime(long createTime) {
		this.createTime = createTime;
	}
	public List<Comment> getComments() {
		return comments;
	}
	public void setComments(List<Comment> comments) {
		this.comments = comments;
	}
	public int getVisitCount() {
		return visitCount;
	}
	public void setVisitCount(int visitCount) {
		this.visitCount = visitCount;
	}
}
